﻿#include<iostream>
using namespace std;

int& add()
{
	int b = { 1 };
	int& c = b;
	int* a = { &b };

	cout << typeid(c).name() << endl;//int
	cout << typeid(&c).name() << endl;//int * __ptr64

	cout << endl;

	cout << typeid(a).name() << endl;//int * __ptr64
	cout << typeid(*a).name() << endl;//int
	cout << typeid(&a).name() << endl;//int * __ptr64 * __ptr64

	cout << c << endl;//1
	cout << &c << endl;//000000F75799F8F4

	cout << a << endl;//000000F75799FA34
	cout << *a << endl;//2
	cout << &a << endl;//000000F75799FA10

	return c;
}
int main() {
	int a{ 1 };
	int* b = { &a };
	int& c = { a };
	add();
	cout << (*b) << endl;

}